<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.5"/>
<title>dpdma: xdpdma.c File Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
  $(window).load(resizeHeight);
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="HTML_custom.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="xlogo_bg.png"/></td>
  <td style="padding-left: 0.5em;">
   <div id="projectname">dpdma
   </div>
   <div id="projectbrief">Vitis Drivers API Documentation</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.5 -->
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Overview</span></a></li>
      <li><a href="globals.html"><span>APIs</span></a></li>
      <li><a href="files.html"><span>File&#160;List</span></a></li>
    </ul>
  </div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('xdpdma_8c.html','');});
</script>
<div id="doc-content">
<div class="header">
  <div class="summary">
<a href="#func-members">Functions</a>  </div>
  <div class="headertitle">
<div class="title">xdpdma.c File Reference</div>  </div>
</div><!--header-->
<div class="contents">
<a name="details" id="details"></a><h2 class="groupheader">Overview</h2>
<div class="textblock"><p>This file contains the implementation of the interface functions of the XDpDma driver. </p>
<p>Refer to <a class="el" href="xdpdma_8h.html" title="This file defines the functions implemented by the DPDMA driver present in the Zynq Ultrascale MP...">xdpdma.h</a> for detailed information.</p>
<dl class="section note"><dt>Note</dt><dd>None.</dd></dl>
<pre>
MODIFICATION HISTORY:</pre><pre>Ver     Who   Date     Changes
</p>
<hr/>
<p>
1.0  aad   04/12/16 Initial release.
1.1  aad   04/26/18 Fixed Warnings
1.6  arm   11/27/23 Fixed Coverity Warnings
</pre> </div><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:a644e1a27df9327819d6fce610e97bae1"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="xdpdma_8c.html#a644e1a27df9327819d6fce610e97bae1">XDpDma_CfgInitialize</a> (XDpDma *InstancePtr, XDpDma_Config *CfgPtr)</td></tr>
<tr class="memdesc:a644e1a27df9327819d6fce610e97bae1"><td class="mdescLeft">&#160;</td><td class="mdescRight">This functions retrieves the configuration for this DPDMA driver and fills in the InstancePtr-&gt;Config structure.  <a href="#a644e1a27df9327819d6fce610e97bae1">More...</a><br/></td></tr>
<tr class="separator:a644e1a27df9327819d6fce610e97bae1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:af852eb781100e5f56cb62d9cc9887fb6"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="xdpdma_8c.html#af852eb781100e5f56cb62d9cc9887fb6">XDpDma_SetChannelState</a> (XDpDma *InstancePtr, XDpDma_ChannelType Channel, XDpDma_ChannelState ChannelState)</td></tr>
<tr class="memdesc:af852eb781100e5f56cb62d9cc9887fb6"><td class="mdescLeft">&#160;</td><td class="mdescRight">This functions controls the states in which a channel should go into.  <a href="#af852eb781100e5f56cb62d9cc9887fb6">More...</a><br/></td></tr>
<tr class="separator:af852eb781100e5f56cb62d9cc9887fb6"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:acb67495006228d9b631e3824c822f56d"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="xdpdma_8c.html#acb67495006228d9b631e3824c822f56d">XDpDma_SetVideoFormat</a> (XDpDma *InstancePtr, XAVBuf_VideoFormat Format)</td></tr>
<tr class="memdesc:acb67495006228d9b631e3824c822f56d"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function allocates DPDMA Video Channels depending on the number of planes in the video.  <a href="#acb67495006228d9b631e3824c822f56d">More...</a><br/></td></tr>
<tr class="separator:acb67495006228d9b631e3824c822f56d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a3307b5795328ef76c76674588918739d"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="xdpdma_8c.html#a3307b5795328ef76c76674588918739d">XDpDma_SetGraphicsFormat</a> (XDpDma *InstancePtr, XAVBuf_VideoFormat Format)</td></tr>
<tr class="memdesc:a3307b5795328ef76c76674588918739d"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function allocates DPDMA Graphics Channels.  <a href="#a3307b5795328ef76c76674588918739d">More...</a><br/></td></tr>
<tr class="separator:a3307b5795328ef76c76674588918739d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ac04dd8bf90f181c5ca44af2b0bd1e3d2"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="xdpdma_8c.html#ac04dd8bf90f181c5ca44af2b0bd1e3d2">XDpDma_SetQOS</a> (XDpDma *InstancePtr, u8 QOS)</td></tr>
<tr class="memdesc:ac04dd8bf90f181c5ca44af2b0bd1e3d2"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function starts the operation on the a given channel.  <a href="#ac04dd8bf90f181c5ca44af2b0bd1e3d2">More...</a><br/></td></tr>
<tr class="separator:ac04dd8bf90f181c5ca44af2b0bd1e3d2"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa031afe32833d3c31cf50c1245d6a5a3"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="xdpdma_8c.html#aa031afe32833d3c31cf50c1245d6a5a3">XDpDma_Trigger</a> (XDpDma *InstancePtr, XDpDma_ChannelType Channel)</td></tr>
<tr class="memdesc:aa031afe32833d3c31cf50c1245d6a5a3"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function Triggers DPDMA to start the transaction.  <a href="#aa031afe32833d3c31cf50c1245d6a5a3">More...</a><br/></td></tr>
<tr class="separator:aa031afe32833d3c31cf50c1245d6a5a3"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a33d14a186926a53012087f81a4fd3f16"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="xdpdma_8c.html#a33d14a186926a53012087f81a4fd3f16">XDpDma_ReTrigger</a> (XDpDma *InstancePtr, XDpDma_ChannelType Channel)</td></tr>
<tr class="memdesc:a33d14a186926a53012087f81a4fd3f16"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function Retriggers DPDMA to fetch data from new descriptor.  <a href="#a33d14a186926a53012087f81a4fd3f16">More...</a><br/></td></tr>
<tr class="separator:a33d14a186926a53012087f81a4fd3f16"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a830dfc769c7cd83f4d55e72217863b93"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="xdpdma_8c.html#a830dfc769c7cd83f4d55e72217863b93">XDpDma_InitVideoDescriptor</a> (XDpDma_Descriptor *CurrDesc, XDpDma_FrameBuffer *FrameBuffer)</td></tr>
<tr class="memdesc:a830dfc769c7cd83f4d55e72217863b93"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function initializes Video Descriptor for Video and Graphics channel.  <a href="#a830dfc769c7cd83f4d55e72217863b93">More...</a><br/></td></tr>
<tr class="separator:a830dfc769c7cd83f4d55e72217863b93"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a3b54f9c726866282dbbe546b1f5ebd55"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="xdpdma_8c.html#a3b54f9c726866282dbbe546b1f5ebd55">XDpDma_InitAudioDescriptor</a> (XDpDma_AudioChannel *Channel, XDpDma_AudioBuffer *AudioBuffer)</td></tr>
<tr class="memdesc:a3b54f9c726866282dbbe546b1f5ebd55"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function initializes Descriptors for transactions on Audio Channel.  <a href="#a3b54f9c726866282dbbe546b1f5ebd55">More...</a><br/></td></tr>
<tr class="separator:a3b54f9c726866282dbbe546b1f5ebd55"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a17566416aab41ddfefa7ebb65146223f"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="xdpdma_8c.html#a17566416aab41ddfefa7ebb65146223f">XDpDma_DisplayVideoFrameBuffer</a> (XDpDma *InstancePtr, XDpDma_FrameBuffer *Plane0, XDpDma_FrameBuffer *Plane1, XDpDma_FrameBuffer *Plane2)</td></tr>
<tr class="memdesc:a17566416aab41ddfefa7ebb65146223f"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function sets the next Frame Buffers to be displayed on the Video Channel.  <a href="#a17566416aab41ddfefa7ebb65146223f">More...</a><br/></td></tr>
<tr class="separator:a17566416aab41ddfefa7ebb65146223f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4b37c9c5a788e141ca8492131af1f980"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="xdpdma_8c.html#a4b37c9c5a788e141ca8492131af1f980">XDpDma_DisplayGfxFrameBuffer</a> (XDpDma *InstancePtr, XDpDma_FrameBuffer *Plane)</td></tr>
<tr class="memdesc:a4b37c9c5a788e141ca8492131af1f980"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function sets the next Frame Buffers to be displayed on the Graphics Channel.  <a href="#a4b37c9c5a788e141ca8492131af1f980">More...</a><br/></td></tr>
<tr class="separator:a4b37c9c5a788e141ca8492131af1f980"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aba4cab14f85a787fe924bb785f9cc807"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="xdpdma_8c.html#aba4cab14f85a787fe924bb785f9cc807">XDpDma_PlayAudio</a> (XDpDma *InstancePtr, XDpDma_AudioBuffer *Buffer, u8 ChannelNum)</td></tr>
<tr class="memdesc:aba4cab14f85a787fe924bb785f9cc807"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function sets the next Audio Buffer to be played on Audio Channel 0.  <a href="#aba4cab14f85a787fe924bb785f9cc807">More...</a><br/></td></tr>
<tr class="separator:aba4cab14f85a787fe924bb785f9cc807"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a6699e959f7465984b1c4c9875fafe656"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="xdpdma_8c.html#a6699e959f7465984b1c4c9875fafe656">XDpDma_SetupChannel</a> (XDpDma *InstancePtr, XDpDma_ChannelType Channel)</td></tr>
<tr class="memdesc:a6699e959f7465984b1c4c9875fafe656"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function sets the channel with the latest framebuffer and the available descriptor for transfer on the next Vsync.  <a href="#a6699e959f7465984b1c4c9875fafe656">More...</a><br/></td></tr>
<tr class="separator:a6699e959f7465984b1c4c9875fafe656"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<h2 class="groupheader">Function Documentation</h2>
<a class="anchor" id="a644e1a27df9327819d6fce610e97bae1"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void XDpDma_CfgInitialize </td>
          <td>(</td>
          <td class="paramtype">XDpDma *&#160;</td>
          <td class="paramname"><em>InstancePtr</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">XDpDma_Config *&#160;</td>
          <td class="paramname"><em>CfgPtr</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This functions retrieves the configuration for this DPDMA driver and fills in the InstancePtr-&gt;Config structure. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">InstancePtr</td><td>is a pointer to the driver instance. </td></tr>
    <tr><td class="paramname">CfgPtr</td><td>is a pointer to the configuration structure that will be used to copy the settings from.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>None.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>None. </dd></dl>

<p>Referenced by <a class="el" href="xdpdma__video__example_8h.html#a80296bbf6ce18bd52a48ac07844ec8ea">InitDpDmaSubsystem()</a>.</p>

</div>
</div>
<a class="anchor" id="a4b37c9c5a788e141ca8492131af1f980"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void XDpDma_DisplayGfxFrameBuffer </td>
          <td>(</td>
          <td class="paramtype">XDpDma *&#160;</td>
          <td class="paramname"><em>InstancePtr</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">XDpDma_FrameBuffer *&#160;</td>
          <td class="paramname"><em>Plane</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This function sets the next Frame Buffers to be displayed on the Graphics Channel. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">InstancePtr</td><td>is pointer to the instance of DPDMA. </td></tr>
    <tr><td class="paramname">Plane</td><td>is a pointer to the Frame Buffer structure.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>None.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>None. </dd></dl>

<p>Referenced by <a class="el" href="xdppsu__interrupt_8c.html#a51529144f29c6d0db501353f1082d7cd">DpPsu_Run()</a>.</p>

</div>
</div>
<a class="anchor" id="a17566416aab41ddfefa7ebb65146223f"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void XDpDma_DisplayVideoFrameBuffer </td>
          <td>(</td>
          <td class="paramtype">XDpDma *&#160;</td>
          <td class="paramname"><em>InstancePtr</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">XDpDma_FrameBuffer *&#160;</td>
          <td class="paramname"><em>Plane0</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">XDpDma_FrameBuffer *&#160;</td>
          <td class="paramname"><em>Plane1</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">XDpDma_FrameBuffer *&#160;</td>
          <td class="paramname"><em>Plane2</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This function sets the next Frame Buffers to be displayed on the Video Channel. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">InstancePtr</td><td>is pointer to the instance of DPDMA. </td></tr>
    <tr><td class="paramname">Plane0</td><td>is a pointer to the Frame Buffer structure. </td></tr>
    <tr><td class="paramname">Plane1</td><td>is a pointer to the Frame Buffer structure. </td></tr>
    <tr><td class="paramname">Plane2</td><td>is a pointer to the Frame Buffer structure.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>None.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>For interleaved mode use Plane0. For semi-planar mode use Plane0 and Plane1. For planar mode use Plane0, Plane1 and Plane2 </dd></dl>

</div>
</div>
<a class="anchor" id="a3b54f9c726866282dbbe546b1f5ebd55"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void XDpDma_InitAudioDescriptor </td>
          <td>(</td>
          <td class="paramtype">XDpDma_AudioChannel *&#160;</td>
          <td class="paramname"><em>Channel</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">XDpDma_AudioBuffer *&#160;</td>
          <td class="paramname"><em>AudioBuffer</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This function initializes Descriptors for transactions on Audio Channel. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">Channel</td><td>is a pointer to the XDpDma_AudioChannel instance</td></tr>
    <tr><td class="paramname">AudioBuffer</td><td>is a pointer to the Audio Buffer structure</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>None.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>None. </dd></dl>

<p>Referenced by <a class="el" href="xdpdma_8c.html#aba4cab14f85a787fe924bb785f9cc807">XDpDma_PlayAudio()</a>, and <a class="el" href="xdpdma_8c.html#a6699e959f7465984b1c4c9875fafe656">XDpDma_SetupChannel()</a>.</p>

</div>
</div>
<a class="anchor" id="a830dfc769c7cd83f4d55e72217863b93"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void XDpDma_InitVideoDescriptor </td>
          <td>(</td>
          <td class="paramtype">XDpDma_Descriptor *&#160;</td>
          <td class="paramname"><em>CurrDesc</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">XDpDma_FrameBuffer *&#160;</td>
          <td class="paramname"><em>FrameBuffer</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This function initializes Video Descriptor for Video and Graphics channel. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">CurrDesc</td><td>is a pointer to the current Descriptor of Video or Graphics Channel. </td></tr>
    <tr><td class="paramname">FrameBuffer</td><td>is a pointer to the Frame Buffer structure</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>None.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>None. </dd></dl>

<p>Referenced by <a class="el" href="xdpdma_8c.html#a6699e959f7465984b1c4c9875fafe656">XDpDma_SetupChannel()</a>.</p>

</div>
</div>
<a class="anchor" id="aba4cab14f85a787fe924bb785f9cc807"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int XDpDma_PlayAudio </td>
          <td>(</td>
          <td class="paramtype">XDpDma *&#160;</td>
          <td class="paramname"><em>InstancePtr</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">XDpDma_AudioBuffer *&#160;</td>
          <td class="paramname"><em>Buffer</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">u8&#160;</td>
          <td class="paramname"><em>ChannelNum</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This function sets the next Audio Buffer to be played on Audio Channel 0. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">InstancePtr</td><td>is pointer to the instance of DPDMA. </td></tr>
    <tr><td class="paramname">Buffer</td><td>is a pointer to the attributes of the Audio information to be played. </td></tr>
    <tr><td class="paramname">ChannelNum</td><td>selects between Audio Channel 0 and Audio Channel 1</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>XST_SUCCESS when the play audio request is successful. XST_FAILURE when the play audio request fails, user has to retry to play the audio.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>The user has to schedule new audio buffer before half the audio information is consumed by DPDMA to have a seamless playback. </dd></dl>

<p>References <a class="el" href="xdpdma_8c.html#a3b54f9c726866282dbbe546b1f5ebd55">XDpDma_InitAudioDescriptor()</a>.</p>

</div>
</div>
<a class="anchor" id="a33d14a186926a53012087f81a4fd3f16"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int XDpDma_ReTrigger </td>
          <td>(</td>
          <td class="paramtype">XDpDma *&#160;</td>
          <td class="paramname"><em>InstancePtr</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">XDpDma_ChannelType&#160;</td>
          <td class="paramname"><em>Channel</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This function Retriggers DPDMA to fetch data from new descriptor. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">InstancePtr</td><td>is a pointer to the XDpDma instance. </td></tr>
    <tr><td class="paramname">Channel</td><td>is the XDpDma_ChannelType on which the transaction is to be retriggered.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>XST_SUCCESS The channel has successfully been Triggered. XST_FAILURE When the triggering Video and Graphics channel without setting the Video Formats.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>None. </dd></dl>

<p>References <a class="el" href="xdpdma__hw_8h.html#acd9b1930d59d62b2de10bcebfe383b5e">XDPDMA_GBL</a>, and <a class="el" href="xdpdma__hw_8h.html#a836430cbab9cc5f0fae3b5f2b54daca6">XDpDma_WriteReg</a>.</p>

<p>Referenced by <a class="el" href="xdpdma__intr_8c.html#aecdf54c8a3174a7547021952de639875">XDpDma_VSyncHandler()</a>.</p>

</div>
</div>
<a class="anchor" id="af852eb781100e5f56cb62d9cc9887fb6"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int XDpDma_SetChannelState </td>
          <td>(</td>
          <td class="paramtype">XDpDma *&#160;</td>
          <td class="paramname"><em>InstancePtr</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">XDpDma_ChannelType&#160;</td>
          <td class="paramname"><em>Channel</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">XDpDma_ChannelState&#160;</td>
          <td class="paramname"><em>ChannelState</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This functions controls the states in which a channel should go into. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">InstancePtr</td><td>is a pointer to the driver instance. </td></tr>
    <tr><td class="paramname">Channel</td><td>is an enum of XDpDma_ChannelType. </td></tr>
    <tr><td class="paramname">ChannelState</td><td>is an enum of type XDpDma_ChannelState.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>XST_SUCCESS when the mentioned channel is enabled successfully. XST_FAILURE when the mentioned channel fails to be enabled.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>None. </dd></dl>

<p>Referenced by <a class="el" href="xdppsu__interrupt_8c.html#a51529144f29c6d0db501353f1082d7cd">DpPsu_Run()</a>, <a class="el" href="xdpdma__intr_8c.html#a856c484c8e45df996ba6aa97f38392dd">XDpDma_InterruptHandler()</a>, and <a class="el" href="xdpdma__intr_8c.html#aecdf54c8a3174a7547021952de639875">XDpDma_VSyncHandler()</a>.</p>

</div>
</div>
<a class="anchor" id="a3307b5795328ef76c76674588918739d"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int XDpDma_SetGraphicsFormat </td>
          <td>(</td>
          <td class="paramtype">XDpDma *&#160;</td>
          <td class="paramname"><em>InstancePtr</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">XAVBuf_VideoFormat&#160;</td>
          <td class="paramname"><em>Format</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This function allocates DPDMA Graphics Channels. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">InstancePtr</td><td>is a pointer to the driver instance. </td></tr>
    <tr><td class="paramname">Format</td><td>is the video format to be used for the DPDMA transfer</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>XST_SUCCESS, When the format is a valid Graphics Format. XST_FAILURE, When the format is not valid Graphics Format.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>None. </dd></dl>

<p>Referenced by <a class="el" href="xdpdma__video__example_8h.html#a80296bbf6ce18bd52a48ac07844ec8ea">InitDpDmaSubsystem()</a>.</p>

</div>
</div>
<a class="anchor" id="ac04dd8bf90f181c5ca44af2b0bd1e3d2"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void XDpDma_SetQOS </td>
          <td>(</td>
          <td class="paramtype">XDpDma *&#160;</td>
          <td class="paramname"><em>InstancePtr</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">u8&#160;</td>
          <td class="paramname"><em>QOS</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This function starts the operation on the a given channel. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">InstancePtr</td><td>is a pointer to the driver instance. </td></tr>
    <tr><td class="paramname">QOS</td><td>is the Quality of Service value to be selected.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>None.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>. </dd></dl>

<p>References <a class="el" href="xdpdma__hw_8h.html#a92edcf2bfb1c790b8168ebdca1297987">XDPDMA_CH0_CNTL</a>, and <a class="el" href="xdpdma__hw_8h.html#a6740ca444093c5883a293e6282d79ec7">XDpDma_ReadModifyWrite</a>.</p>

<p>Referenced by <a class="el" href="xdpdma__video__example_8h.html#a80296bbf6ce18bd52a48ac07844ec8ea">InitDpDmaSubsystem()</a>.</p>

</div>
</div>
<a class="anchor" id="a6699e959f7465984b1c4c9875fafe656"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void XDpDma_SetupChannel </td>
          <td>(</td>
          <td class="paramtype">XDpDma *&#160;</td>
          <td class="paramname"><em>InstancePtr</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">XDpDma_ChannelType&#160;</td>
          <td class="paramname"><em>Channel</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This function sets the channel with the latest framebuffer and the available descriptor for transfer on the next Vsync. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">InstancePtr</td><td>is pointer to the instance of DPDMA. </td></tr>
    <tr><td class="paramname">Channel</td><td>indicates which channels are being setup for transfer.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>None.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>None. </dd></dl>

<p>References <a class="el" href="xdpdma_8c.html#a3b54f9c726866282dbbe546b1f5ebd55">XDpDma_InitAudioDescriptor()</a>, and <a class="el" href="xdpdma_8c.html#a830dfc769c7cd83f4d55e72217863b93">XDpDma_InitVideoDescriptor()</a>.</p>

<p>Referenced by <a class="el" href="xdpdma__intr_8c.html#aecdf54c8a3174a7547021952de639875">XDpDma_VSyncHandler()</a>.</p>

</div>
</div>
<a class="anchor" id="acb67495006228d9b631e3824c822f56d"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int XDpDma_SetVideoFormat </td>
          <td>(</td>
          <td class="paramtype">XDpDma *&#160;</td>
          <td class="paramname"><em>InstancePtr</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">XAVBuf_VideoFormat&#160;</td>
          <td class="paramname"><em>Format</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This function allocates DPDMA Video Channels depending on the number of planes in the video. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">InstancePtr</td><td>is a pointer to the driver instance. </td></tr>
    <tr><td class="paramname">Format</td><td>is the video format to be used for the DPDMA transfer</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>XST_SUCCESS, When the format is valid Video Format. XST_FAILURE, When the format is not valid Video Format</dd></dl>
<dl class="section note"><dt>Note</dt><dd>None. </dd></dl>

</div>
</div>
<a class="anchor" id="aa031afe32833d3c31cf50c1245d6a5a3"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int XDpDma_Trigger </td>
          <td>(</td>
          <td class="paramtype">XDpDma *&#160;</td>
          <td class="paramname"><em>InstancePtr</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">XDpDma_ChannelType&#160;</td>
          <td class="paramname"><em>Channel</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This function Triggers DPDMA to start the transaction. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">InstancePtr</td><td>is a pointer to the XDpDma instance. </td></tr>
    <tr><td class="paramname">Channel</td><td>is the XDpDma_ChannelType on which the transaction is to be triggered.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>XST_SUCCESS The channel has successfully been Triggered. XST_FAILURE When the triggering Video and Graphics channel without setting the Video Formats.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>None. </dd></dl>

<p>References <a class="el" href="xdpdma__hw_8h.html#acd9b1930d59d62b2de10bcebfe383b5e">XDPDMA_GBL</a>, and <a class="el" href="xdpdma__hw_8h.html#a836430cbab9cc5f0fae3b5f2b54daca6">XDpDma_WriteReg</a>.</p>

<p>Referenced by <a class="el" href="xdpdma__intr_8c.html#aecdf54c8a3174a7547021952de639875">XDpDma_VSyncHandler()</a>.</p>

</div>
</div>
</div><!-- contents -->
</div><!-- doc-content -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
	<p class="footer">&copy; Copyright 2015-2022 Xilinx, Inc. All Rights Reserved.</p>
	<p class="footer">&copy; Copyright 2022-2023 Advanced Micro Devices, Inc. All Rights Reserved.</p>
</div>
</body>
</html>
